<script setup lang="ts" name="guide">
import { getUrlParam } from '@/utils';
interface Props {
    show: boolean;
}

const props = withDefaults(defineProps<Props>(), {
    show: false
});
const payType = getUrlParam('payType') || 'code';
</script>

<template>
    <div class="guide-box" v-if="props.show">
        <div class="main-box">
            <img
                v-if="payType !== 'code'"
                src="~@/assets/images/icon-scan.png"
                width="64"
                height="64"
            />
            <img v-else src="~@/assets/images/web-guide.png" width="215" height="285" />
            <div :class="`${payType === 'code' ? 'info-text' : 'scan-text'}`">
                请使用微信或支付宝扫码
            </div>
        </div>
    </div>
</template>

<style lang="less" scoped>
.guide-box {
    background-color: #ffffff;
    height: 100vh;
}
.main-box {
    position: relative;
    padding-top: 120px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-weight: 500;
    font-size: 20px;
    line-height: 28px;
    color: #1a1a1a;
}

.scan-text {
    margin-top: 12px;
    width: 100%;
    text-align: center;
}

.info-text {
    position: absolute;
    bottom: 26px;
    width: 100%;
    text-align: center;
}
</style>
